package com.jun.serviceimpl;

import com.jun.entity.UserConsume;
import com.jun.mapper.UserConsumeMapper;
import com.jun.service.UserConsumeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.Map;

@Service
@Transactional
public class UserConsumeServiceImpl implements UserConsumeService {
    @Autowired
    UserConsumeMapper userConsumeMapper;
    @Override
    public int insertUserConsume(UserConsume userConsume) {
        return userConsumeMapper.insertUserConsume(userConsume);
    }

    @Override
    public String searchOneDayConsume(String time) {
        return userConsumeMapper.searchOneDayConsume(time);
    }

    @Override
    public String searchUserConsumeByInterval(Map<String, Object> map) {
        return userConsumeMapper.searchUserConsumeByInterval(map);
    }
}
